<%--
  Created by IntelliJ IDEA.
  User: zhangyading
  Date: 2021/8/21
  Time: 4:15
  To change this template use File | Settings | File Templates.
--%>
<%@ page contentType="text/html;charset=UTF-8" language="java" %>
<html>
<head>
    <title>Title</title>
</head>
<body>
    <!--文件上传三要素-->
    <%--
        1.表单提交方式必须是post
        2.表单的entype属性必须为：multipart/from-data
        3.表单中必须有文件上传项
    --%>
    <form method="post" enctype="multipart/form-data" action="${pageContext.request.contextPath}/upload">
        <input type="file" name="upload">
        <br>
        <input type="text" name="name">
        <input type="text" name="password">
        <input type="submit" value="文件上传">
    </form>

    <img src="/upload/21a280d0038d4871a7a43c150262a431_book-01.jpg">
</body>
</html>
